Simulink Code Inspector Report for yaw_damper.slx


Inspected Model File : C:\Users\bpotter\LocalWorkArea\demos\autopilot_R2013b_workarea\yaw_damper.slx
Model Version : 1.80
Simulink Version : 8.2 (R2013b)
Model Checksum : 3650268267 1334015131 586674754 1215105841
Model Last Modified On : 28-Jan-2014 07:27:39
Inspected Code Files : C:\Users\bpotter\LocalWorkArea\demos\autopilot_R2013b_workarea\slprj\ert\_sharedutils\const_params.c
C:\Users\bpotter\LocalWorkArea\demos\autopilot_R2013b_workarea\slprj\ert\yaw_damper\yaw_damper.c
Code Inspection Run On : 03-Feb-2014 08:16:08
 
Overall Inspection Result : Passed

Code Verification Results : Verified

Function Interface Verification Results : Verified

Function Status Details
yaw_damper_initialize Verified -
yaw_damper Verified -

Model To Code Verification Results : Verified

Status Details
Verified
Model objects with status Verified : 25
Model objects with status Partially processed : 0
Model objects with status Unable to process : 0
Model objects with status Failed to verify : 0

Code To Model Verification Results : Verified

Function Status Details
yaw_damper_initialize Verified
Lines of code with status Verified : 2
Lines of code with status Partially processed : 0
Lines of code with status Unable to process : 0
Lines of code with status Failed to verify : 0
yaw_damper Verified
Lines of code with status Verified : 15
Lines of code with status Partially processed : 0
Lines of code with status Unable to process : 0
Lines of code with status Failed to verify : 0

Temporary Variable Usage Results : Verified

Function Status Details
yaw_damper_initialize Verified
Function does not have any temporary variable declarations
yaw_damper Verified
Temporary variables with status Failed to verify : 0
Temporary variables with status Verified : 2


Traceability Results : Traced

Model To Code Traceability Results : Traced

Status Number of model objects
Traced 25
Partially processed 0
Unable to process 0
Failed to trace 0

Code To Model Traceability Results : Traced

Status Number of code lines
Traced 23
Nonfunctional code 62
Not processed 2
Partially processed 0
Unable to process 0
Failed to trace 0

Not processed code:

File : yaw_damper.c

Code location Code
16 #include "yaw_damper.h"
17 #include "yaw_damper_private.h"



Code Verification Details

[-] Function Interface Verification
[-] Function : yaw_damper_initialize
Check Status
Number of function arguments Verified
Function argument names Verified
Function argument data types Verified
Function return type Verified
[-] Function : yaw_damper
Check Status
Number of function arguments Verified
Function argument names Verified
Function argument data types Verified
Function return type Verified
[-] Model To Code Verification
Model : yaw_damper
Model object Status Details
<model>/Phi Verified
Virtual/Eliminated (Inport)
<model>/R Verified
Virtual/Eliminated (Inport)
<model>/TAS Verified
Virtual/Eliminated (Inport)
<model>/AP Eng Verified
Virtual/Eliminated (Inport)
<model>/Basic Yaw Damper Verified
Inlined (SubSystem)
<model>/Basic Yaw Damper/Phi Verified
Virtual/Eliminated (Inport)
<model>/Basic Yaw Damper/R Verified
Virtual/Eliminated (Inport)
<model>/Basic Yaw Damper/TAS Verified
Virtual/Eliminated (Inport)
<model>/Basic Yaw Damper/Constant Verified
-
<model>/Basic Yaw Damper/MinMax Verified
-
<model>/Basic Yaw Damper/Model Info Verified
Virtual/Eliminated (Model Info block)
<model>/Basic Yaw Damper/Product Verified
-
<model>/Basic Yaw Damper/Rate Gain Verified
-
<model>/Basic Yaw Damper/Rud Limit Verified
-
<model>/Basic Yaw Damper/Sum1 Verified
-
<model>/Basic Yaw Damper/gravity Verified
-
<model>/Basic Yaw Damper/sin Verified
-
<model>/Basic Yaw Damper/Rud Cmd Verified
Virtual/Eliminated (Outport)
<model>/Constant Verified
-
<model>/Eng switch Verified
-
<model>/Model Info Verified
Virtual/Eliminated (Model Info block)
<model>/Rud Cmd Verified
-
<model>/Basic Yaw Damper/Model Info/EmptySubsystem Verified
Virtual/Eliminated (SubSystem)
<model>/Model Info/EmptySubsystem Verified
Virtual/Eliminated (SubSystem)
block I/O initialization code Verified
-
[-] Code To Model Verification
[-] Function : yaw_damper_initialize
Function outputs/state variables Contributing lines of code
*localB.yawRate Verified
yaw_damper.c:79 Verified
yaw_damper.c:80 Verified
[-] Function : yaw_damper
Function outputs/state variables Contributing lines of code
*localB.yawRate Verified
yaw_damper.c:31 Verified
yaw_damper.c:32 Verified
yaw_damper.c:33 Verified
yaw_damper.c:34 Verified
yaw_damper.c:43 Verified
*rty_RudCmd Verified
yaw_damper.c:31 Verified
yaw_damper.c:32 Verified
yaw_damper.c:33 Verified
yaw_damper.c:34 Verified
yaw_damper.c:43 Verified
yaw_damper.c:50 Verified
yaw_damper.c:53 Verified
yaw_damper.c:56 Verified
yaw_damper.c:57 Verified
yaw_damper.c:58 Verified
yaw_damper.c:59 Verified
yaw_damper.c:60 Verified
yaw_damper.c:61 Verified
yaw_damper.c:66 Verified
yaw_damper.c:67 Verified
[-] Temporary Variable Usage
[-] Function : yaw_damper_initialize
Function does not have any temporary variable declarations
[-] Function : yaw_damper
Temporary variable name Status
u Verified
y Verified

Traceability Details

[-] Model To Code Traceability
Model : yaw_damper
Model object Code location Details
<model>/Phi
-
Virtual/Eliminated (Inport)
<model>/R
-
Virtual/Eliminated (Inport)
<model>/TAS
-
Virtual/Eliminated (Inport)
<model>/AP Eng
-
Virtual/Eliminated (Inport)
<model>/Basic Yaw Damper
-
Inlined (SubSystem)
<model>/Basic Yaw Damper/Phi
-
Virtual/Eliminated (Inport)
<model>/Basic Yaw Damper/R
-
Virtual/Eliminated (Inport)
<model>/Basic Yaw Damper/TAS
-
Virtual/Eliminated (Inport)
<model>/Basic Yaw Damper/Constant
yaw_damper.c:31 , 34
-
<model>/Basic Yaw Damper/MinMax
yaw_damper.c:31 , 33
-
<model>/Basic Yaw Damper/Model Info
-
Virtual/Eliminated (Model Info block)
<model>/Basic Yaw Damper/Product
yaw_damper.c:43
-
<model>/Basic Yaw Damper/Rate Gain
yaw_damper.c:53
-
<model>/Basic Yaw Damper/Rud Limit
yaw_damper.c:56-60
-
<model>/Basic Yaw Damper/Sum1
yaw_damper.c:43
-
<model>/Basic Yaw Damper/gravity
yaw_damper.c:43
-
<model>/Basic Yaw Damper/sin
yaw_damper.c:43
-
<model>/Basic Yaw Damper/Rud Cmd
-
Virtual/Eliminated (Outport)
<model>/Constant
yaw_damper.c:67
-
<model>/Eng switch
yaw_damper.c:50 , 66
-
<model>/Model Info
-
Virtual/Eliminated (Model Info block)
<model>/Rud Cmd
yaw_damper.c:57 , 59 , 61 , 67
-
<model>/Basic Yaw Damper/Model Info/EmptySubsystem
-
Virtual/Eliminated (SubSystem)
<model>/Model Info/EmptySubsystem
-
Virtual/Eliminated (SubSystem)
block I/O initialization code
yaw_damper.c:79-80
-
[-] Code To Model Traceability
File : yaw_damper.c
Code location Code Model object Details
1 /*
-
Nonfunctional code (Comment)
2 * File: yaw_damper.c
-
Nonfunctional code (Comment)
3 *
-
Nonfunctional code (Comment)
4 * Code generated for Simulink model 'yaw_damper'.
-
Nonfunctional code (Comment)
5 *
-
Nonfunctional code (Comment)
6 * Model version : 1.80
-
Nonfunctional code (Comment)
7 * Simulink Coder version : 8.5 (R2013b) 08-Aug-2013
-
Nonfunctional code (Comment)
8 * C/C++ source code generated on : Mon Feb 03 08:13:39 2014
-
Nonfunctional code (Comment)
9 *
-
Nonfunctional code (Comment)
10 * Target selection: ert.tlc
-
Nonfunctional code (Comment)
11 * Embedded hardware selection: 32-bit Embedded Processor
-
Nonfunctional code (Comment)
12 * Code generation objectives: Unspecified
-
Nonfunctional code (Comment)
13 * Validation result: Not run
-
Nonfunctional code (Comment)
14 */
-
Nonfunctional code (Comment)
15
-
Nonfunctional code (Empty line)
16 #include "yaw_damper.h"
-
Not processed (Include statement)
17 #include "yaw_damper_private.h"
-
Not processed (Include statement)
18
-
Nonfunctional code (Empty line)
19 /* Output and update for referenced model: 'yaw_damper' */
-
Nonfunctional code (Comment)
20 void yaw_damper(const real_T *rtu_Phi, const real_T *rtu_R, const real_T
output function interface
-
21 *rtu_TAS, const boolean_T *rtu_APEng, real_T *rty_RudCmd,
output function interface
-
22 rtB_yaw_damper *localB, real_T rtp_rateGain)
output function interface
-
23 {
-
Nonfunctional code (Start of code segment)
24 real_T u;
-
Local variable declaration
25 real_T y;
-
Local variable declaration
26
-
Nonfunctional code (Empty line)
27 /* Outputs for Atomic SubSystem: '<Root>/Basic Yaw Damper' */
-
Nonfunctional code (Comment)
28 /* MinMax: '<S1>/MinMax' incorporates:
-
Nonfunctional code (Comment)
29 * Constant: '<S1>/Constant'
-
Nonfunctional code (Comment)
30 */
-
Nonfunctional code (Comment)
31 if ((*rtu_TAS) >= 100.0) {
<model>/Basic Yaw Damper/MinMax
<model>/Basic Yaw Damper/Constant
<model>/TAS
-
32 y = *rtu_TAS;
<model>/TAS
-
33 } else {
<model>/Basic Yaw Damper/MinMax
-
34 y = 100.0;
<model>/Basic Yaw Damper/Constant
-
35 }
-
Nonfunctional code (End of code segment)
36
-
Nonfunctional code (Empty line)
37 /* Sum: '<S1>/Sum1' incorporates:
-
Nonfunctional code (Comment)
38 * Gain: '<S1>/gravity'
-
Nonfunctional code (Comment)
39 * MinMax: '<S1>/MinMax'
-
Nonfunctional code (Comment)
40 * Product: '<S1>/Product'
-
Nonfunctional code (Comment)
41 * Trigonometry: '<S1>/sin'
-
Nonfunctional code (Comment)
42 */
-
Nonfunctional code (Comment)
43 localB->yawRate = ((32.2 * sin(*rtu_Phi)) / y) - (*rtu_R);
<model>/Phi
<model>/Basic Yaw Damper/Sum1
<model>/Basic Yaw Damper/gravity
<model>/Basic Yaw Damper/sin
<model>/R
<model>/Basic Yaw Damper/Product
-
44
-
Nonfunctional code (Empty line)
45 /* End of Outputs for SubSystem: '<Root>/Basic Yaw Damper' */
-
Nonfunctional code (Comment)
46
-
Nonfunctional code (Empty line)
47 /* Switch: '<Root>/Eng switch' incorporates:
-
Nonfunctional code (Comment)
48 * Constant: '<Root>/Constant'
-
Nonfunctional code (Comment)
49 */
-
Nonfunctional code (Comment)
50 if (*rtu_APEng) {
<model>/Eng switch
<model>/AP Eng
-
51 /* Outputs for Atomic SubSystem: '<Root>/Basic Yaw Damper' */
-
Nonfunctional code (Comment)
52 /* Gain: '<S1>/Rate Gain' */
-
Nonfunctional code (Comment)
53 u = rtp_rateGain * localB->yawRate;
<model>/Basic Yaw Damper/Rate Gain
-
54
-
Nonfunctional code (Empty line)
55 /* Saturate: '<S1>/Rud Limit' */
-
Nonfunctional code (Comment)
56 if (u >= 25.0) {
<model>/Basic Yaw Damper/Rud Limit
-
57 *rty_RudCmd = 25.0;
<model>/Basic Yaw Damper/Rud Limit
<model>/Rud Cmd
-
58 } else if (u <= (-25.0)) {
<model>/Basic Yaw Damper/Rud Limit
-
59 *rty_RudCmd = (-25.0);
<model>/Basic Yaw Damper/Rud Limit
<model>/Rud Cmd
-
60 } else {
<model>/Basic Yaw Damper/Rud Limit
-
61 *rty_RudCmd = u;
<model>/Rud Cmd
-
62 }
-
Nonfunctional code (End of code segment)
63
-
Nonfunctional code (Empty line)
64 /* End of Saturate: '<S1>/Rud Limit' */
-
Nonfunctional code (Comment)
65 /* End of Outputs for SubSystem: '<Root>/Basic Yaw Damper' */
-
Nonfunctional code (Comment)
66 } else {
<model>/Eng switch
<model>/AP Eng
-
67 *rty_RudCmd = 0.0;
<model>/Constant
<model>/Rud Cmd
-
68 }
-
Nonfunctional code (End of code segment)
69
-
Nonfunctional code (Empty line)
70 /* End of Switch: '<Root>/Eng switch' */
-
Nonfunctional code (Comment)
71 }
-
Nonfunctional code (End of code segment)
72
-
Nonfunctional code (Empty line)
73 /* Model initialize function */
-
Nonfunctional code (Comment)
74 void yaw_damper_initialize(rtB_yaw_damper *localB)
initialize function interface
-
75 {
-
Nonfunctional code (Start of code segment)
76 /* Registration code */
-
Nonfunctional code (Comment)
77
-
Nonfunctional code (Empty line)
78 /* block I/O */
-
Nonfunctional code (Comment)
79 (void) memset(((void *) localB), 0,
block I/O initialization code
-
80 sizeof(rtB_yaw_damper));
block I/O initialization code
-
81 }
-
Nonfunctional code (End of code segment)
82
-
Nonfunctional code (Empty line)
83 /*
-
Nonfunctional code (Comment)
84 * File trailer for generated code.
-
Nonfunctional code (Comment)
85 *
-
Nonfunctional code (Comment)
86 * [EOF]
-
Nonfunctional code (Comment)
87 */
-
Nonfunctional code (Comment)